﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Media;
using Visifire.Charts;

namespace CPPEI.Coolzon.UI.DataPartLib
{
    public partial class DataChartAxisBase
    {
        private Axis axisY;
        protected Axis getAxisY()
        {
            axisY = new Axis();
            axisY.AxisType = AxisTypes.Primary;
            axisY.Enabled = AxisYEnabled;
            axisY.StartFromZero = AxisYStartFromZero;
            axisY.AxisMinimum = AxisYMinimum;
            axisY.AxisMaximum = AxisYMaximum;
            axisY.IntervalType = AxisYIntervalType;
            axisY.Interval = AxisYInterval;
            axisY.LineStyle = AxisYLineStyle;
            axisY.LineColor = AxisYLineColor == null ? null : AxisYLineColor.Brush;
            axisY.LineThickness = AxisYLineThickness;
            axisY.Title = AxisYTitle ?? "";
            axisY.TitleFontFamily = AxisYTitleFontFamily;
            axisY.TitleFontWeight = AxisYTitleFontWeight;
            axisY.TitleFontSize = AxisYTitleFontSize;
            axisY.TitleFontColor = AxisYTitleFontColor == null? null : AxisYTitleFontColor.Brush;
            axisY.Prefix = AxisYPrefix ?? "";
            axisY.Suffix = AxisYSuffix ?? "";
            axisY.ValueFormatString = AxisYValueFormatString ?? "";
            axisY.Logarithmic = AxisYLogarithmic;
            axisY.LogarithmBase = AxisYLogarithmBase;

            AxisLabels axisLabel = new AxisLabels();
            axisLabel.Enabled = AxisYLabelEnable;
            axisLabel.FontFamily = AxisYLabelFontFamily;
            axisLabel.FontWeight = AxisYLabelFontWeight;
            axisLabel.FontSize = AxisYLabelFontSize;
            axisLabel.FontColor = AxisYLabelFontColor == null ? null : AxisYLabelFontColor.Brush;
            axisLabel.Angle = AxisYLabelAngle;
            axisLabel.Rows = AxisYLabelRows;
            axisLabel.TextAlignment = AxisYLabelTextAlignmnet;
            //axisLabel.Interval = AxisYLabelInterval;
            if (AxisYLabelTextWrap != null)
                axisLabel.TextWrap = AxisYLabelTextWrap.Value;

            axisY.AxisLabels = axisLabel;

            ChartGrid chartGrid = new ChartGrid();
            chartGrid.Enabled = AxisYChartGridEnable;
            chartGrid.LineColor = AxisYChartGridLineColor == null ? null : AxisYChartGridLineColor.Brush;
            chartGrid.LineStyle = AxisYChartGridLineStyle;
            chartGrid.LineThickness = AxisYChartGridLineThickness;
            chartGrid.InterlacedColor = AxisYChartGridInterlacedColor == null? null : AxisYChartGridInterlacedColor.Brush;
            //chartGrid.Interval = AxisYChartGridInterval;
            axisY.Grids.Add(chartGrid);

            Ticks ticks = new Ticks();
            ticks.Enabled = AxisYTickEnabled;
            //ticks.Interval = AxisYTickInterval;
            ticks.LineColor = AxisYTickLineColor == null ? null : AxisYTickLineColor.Brush;
            ticks.LineStyle = AxisYTickLineStyles;
            ticks.LineThickness = AxisYTickLineThickness;
            ticks.TickLength = AxisYTickLength;
            axisY.Ticks.Add(ticks);

            return axisY;
        }

        private bool axisYEnabled;
        private bool axisYStartFromZero;
        private double axisYMinimum;
        private double axisYMaximum;
        private double axisYInterval;
        private Visifire.Charts.LineStyles axisYLineStyle;
        private BrushEx axisYLineColor;
        private int axisYLineThickness;
        private string axisYTitle;
        private FontFamily axisYTitleFontFamily;
        private FontWeight axisYTitleFontWeight;
        private int axisYTitleFontSize;
        private BrushEx axisYTitleFontColor;
        private IntervalTypes axisYIntervalType;
        private string axisYPrefix;
        private string axisYSuffix;
        private string axisYValueFormatString;

        private bool axisYLabelEnable;
        private FontFamily axisYLabelFontFamily;
        private FontWeight axisYLabelFontWeight;
        private int axisYLabelFontSize;
        private BrushEx axisYLabelFontColor;
        private double? axisYLabelAngle;
        private int axisYLabelRows;
        private TextAlignment axisYLabelTextAlignmnet;
        private double? axisYLabelTextWrap;
        private double? axisYLabelInterval;

        private bool axisYChartGridEnable;
        private BrushEx axisYChartGridLineColor;
        private LineStyles axisYChartGridLineStyle;
        private int axisYChartGridLineThickness;
        private BrushEx axisYChartGridInterlacedColor;
        private double? axisYChartGridInterval;

        private bool axisYTickEnabled;
        private double? axisYTickInterval;
        private BrushEx axisYTickLineColor;
        private LineStyles axisYTickLineStyles;
        private double axisYTickLineThickness;
        private double? axisYTickLength;

        #region Axis
        [Category("Y轴")]
        [DisplayName("Y轴是否可用")]
        [Description("AxisYEnabled")]
        [Editor(typeof(UI.XProperty.Editors.XBooleanEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYEnabled", "是否可用")]
        public bool AxisYEnabled
        {
            get
            {
                return axisYEnabled;
            }

            set
            {
                axisYEnabled = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴是否从0开始")]
        [Description("AxisYStartFromZero")]
        [Editor(typeof(UI.XProperty.Editors.XBooleanEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYStartFromZero", "是否从0开始")]
        public bool AxisYStartFromZero
        {
            get
            {
                return axisYStartFromZero;
            }

            set
            {
                axisYStartFromZero = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴最小值")]
        [Description("AxisYMinimum")]
        [Editor(typeof(UI.XProperty.Editors.XDoubleEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYMinimum", "最小值")]
        public double AxisYMinimum
        {
            get
            {
                return axisYMinimum;
            }

            set
            {
                axisYMinimum = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴最大值")]
        [Description("AxisYMaximum")]
        [Editor(typeof(UI.XProperty.Editors.XDoubleEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYMaximum", "最大值")]
        public double AxisYMaximum
        {
            get
            {
                return axisYMaximum;
            }

            set
            {
                axisYMaximum = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴步长")]
        [Description("AxisYInterval")]
        [Editor(typeof(UI.XProperty.Editors.XDoubleEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYInterval", "步长")]
        public double AxisYInterval
        {
            get
            {
                return axisYInterval;
            }

            set
            {
                axisYInterval = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴步长类型")]
        [Description("AxisYIntervalType")]
        [Editor(typeof(UI.DataPartLib.XProperty.Editors.XIntervalTypesEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYIntervalType", "步长类型")]
        public IntervalTypes AxisYIntervalType
        {
            get
            {
                return axisYIntervalType;
            }

            set
            {
                axisYIntervalType = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴线样式")]
        [Description("AxisYLineStyle")]
        [Editor(typeof(UI.DataPartLib.XProperty.Editors.XLineStylesEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLineStyle", "线样式")]
        public LineStyles AxisYLineStyle
        {
            get
            {
                return axisYLineStyle;
            }

            set
            {
                axisYLineStyle = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴线颜色")]
        [Description("AxisYLineColor")]
        [Editor(typeof(UI.XProperty.Editors.XBrushEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLineColor", "线颜色")]
        public BrushEx AxisYLineColor
        {
            get
            {
                return axisYLineColor;
            }

            set
            {
                axisYLineColor = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴线宽度")]
        [Description("AxisYLineThickness")]
        [Editor(typeof(UI.XProperty.Editors.XIntEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLineThickness", "线宽度")]
        public int AxisYLineThickness
        {
            get
            {
                return axisYLineThickness;
            }

            set
            {
                axisYLineThickness = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴标题")]
        [Description("AxisYTitle")]
        [Editor(typeof(UI.XProperty.Editors.XStringEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTitle", "标题")]
        public string AxisYTitle
        {
            get
            {
                return axisYTitle;
            }

            set
            {
                axisYTitle = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴标题字体")]
        [Description("AxisYTitleFontFamily")]
        [Editor(typeof(UI.XProperty.Editors.XFontFamilyEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTitleFontFamily", "标题字体")]
        public FontFamily AxisYTitleFontFamily
        {
            get
            {
                return axisYTitleFontFamily;
            }

            set
            {
                axisYTitleFontFamily = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴标题字体粗细")]
        [Description("AxisYTitleFontWeight")]
        [Editor(typeof(UI.XProperty.Editors.XFontWeightEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTitleFontWeight", "标题字体粗细")]
        public FontWeight AxisYTitleFontWeight
        {
            get
            {
                return axisYTitleFontWeight;
            }

            set
            {
                axisYTitleFontWeight = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴标题字体大小")]
        [Description("AxisYTitleFontSize")]
        [Editor(typeof(UI.XProperty.Editors.XIntEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTitleFontSize", "标题字体大小")]
        public int AxisYTitleFontSize
        {
            get
            {
                return axisYTitleFontSize;
            }

            set
            {
                axisYTitleFontSize = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴标题字体颜色")]
        [Description("AxisYTitleFontColor")]
        [Editor(typeof(UI.XProperty.Editors.XBrushEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTitleFontColor", "标题字体颜色")]
        public BrushEx AxisYTitleFontColor
        {
            get
            {
                return axisYTitleFontColor;
            }

            set
            {
                axisYTitleFontColor = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴前缀")]
        [Description("AxisYPrefix")]
        [Editor(typeof(UI.XProperty.Editors.XStringEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYPrefix", "前缀")]
        public string AxisYPrefix
        {
            get
            {
                return axisYPrefix;
            }

            set
            {
                axisYPrefix = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴后缀")]
        [Description("AxisYSuffix")]
        [Editor(typeof(UI.XProperty.Editors.XStringEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYSuffix", "后缀")]
        public string AxisYSuffix
        {
            get
            {
                return axisYSuffix;
            }

            set
            {
                axisYSuffix = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴格式化")]
        [Description("AxisYValueFormatString")]
        [Editor(typeof(UI.XProperty.Editors.XStringEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYValueFormatString", "格式化")]
        public string AxisYValueFormatString
        {
            get
            {
                return axisYValueFormatString;
            }

            set
            {
                axisYValueFormatString = value;
                Refresh();
            }
        }
        #endregion

        #region AxisLabels
        [Category("Y轴")]
        [DisplayName("Y轴是否显示文本")]
        [Description("AxisYLabelEnable")]
        [Editor(typeof(UI.XProperty.Editors.XBooleanEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLabelEnable", "是否显示文本")]
        public bool AxisYLabelEnable
        {
            get
            {
                return axisYLabelEnable;
            }

            set
            {
                axisYLabelEnable = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴文本字体")]
        [Description("AxisYLabelFontFamily")]
        [Editor(typeof(UI.XProperty.Editors.XFontFamilyEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLabelFontFamily", "文本字体")]
        public FontFamily AxisYLabelFontFamily
        {
            get
            {
                return axisYLabelFontFamily;
            }

            set
            {
                axisYLabelFontFamily = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴文本字体粗细")]
        [Description("AxisYLabelFontWeight")]
        [Editor(typeof(UI.XProperty.Editors.XFontWeightEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLabelFontWeight", "文本字体粗细")]
        public FontWeight AxisYLabelFontWeight
        {
            get
            {
                return axisYLabelFontWeight;
            }

            set
            {
                axisYLabelFontWeight = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴文本字体大小")]
        [Description("AxisYLabelFontSize")]
        [Editor(typeof(UI.XProperty.Editors.XIntEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLabelFontSize", "文本字体大小")]
        public int AxisYLabelFontSize
        {
            get
            {
                return axisYLabelFontSize;
            }

            set
            {
                axisYLabelFontSize = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴文本字体颜色")]
        [Description("AxisYLabelFontColor")]
        [Editor(typeof(UI.XProperty.Editors.XBrushEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLabelFontColor", "文本字体颜色")]
        public BrushEx AxisYLabelFontColor
        {
            get
            {
                return axisYLabelFontColor;
            }

            set
            {
                axisYLabelFontColor = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴文本倾斜角度")]
        [Description("AxisYLabelAngle")]
        [Editor(typeof(UI.XProperty.Editors.XDoubleNullEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLabelAngle", "文本倾斜角度")]
        public double? AxisYLabelAngle
        {
            get
            {
                return axisYLabelAngle;
            }

            set
            {
                axisYLabelAngle = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴文本显示行数")]
        [Description("AxisYLabelRows")]
        [Editor(typeof(UI.XProperty.Editors.XIntEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLabelRows", "文本显示行数")]
        public int AxisYLabelRows
        {
            get
            {
                return axisYLabelRows;
            }

            set
            {
                axisYLabelRows = value;
                Refresh();
            }
        }

        //[Category("Y轴")]
        //[DisplayName("Y轴文本对齐")]
        //[Description("AxisYLabelTextAlignmnet")]
        //[Editor(typeof(UI.XProperty.Editors.XTextAlignmentEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        //[XProperty(XPropertyCategory.Other, "AxisYLabelTextAlignmnet", "文本对齐")]
        public TextAlignment AxisYLabelTextAlignmnet
        {
            get
            {
                return axisYLabelTextAlignmnet;
            }

            set
            {
                axisYLabelTextAlignmnet = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴文本换行(0-1)")]
        [Description("AxisYLabelTextWrap")]
        [Editor(typeof(UI.XProperty.Editors.XDoubleEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYLabelTextWrap", "文本换行(0-1)")]
        public double? AxisYLabelTextWrap
        {
            get
            {
                return axisYLabelTextWrap;
            }

            set
            {
                axisYLabelTextWrap = value;
                Refresh();
            }
        }
        //[Category("Y轴")]
        //[DisplayName("Y轴文本步长")]
        //[Description("AxisYLabelInterval")]
        //[Editor(typeof(UI.XProperty.Editors.XDoubleNullEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        //[XProperty(XPropertyCategory.Other, "AxisYLabelInterval", "文本步长")]
        public double? AxisYLabelInterval
        {
            get
            {
                return axisYLabelInterval;
            }

            set
            {
                axisYLabelInterval = value;
                Refresh();
            }
        }
        #endregion

        #region ChartGrid
        [Category("Y轴")]
        [DisplayName("Y轴是否显示网格线")]
        [Description("AxisYChartGridEnable")]
        [Editor(typeof(UI.XProperty.Editors.XBooleanEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYChartGridEnable", "是否网格线")]
        public bool AxisYChartGridEnable
        {
            get
            {
                return axisYChartGridEnable;
            }

            set
            {
                axisYChartGridEnable = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴网格线颜色")]
        [Description("AxisYChartGridLineColor")]
        [Editor(typeof(UI.XProperty.Editors.XBrushEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYChartGridLineColor", "网格线颜色")]
        public BrushEx AxisYChartGridLineColor
        {
            get
            {
                return axisYChartGridLineColor;
            }

            set
            {
                axisYChartGridLineColor = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴网格线类型")]
        [Description("AxisYChartGridLineStyle")]
        [Editor(typeof(UI.DataPartLib.XProperty.Editors.XLineStylesEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYChartGridLineStyle", "网格线类型")]
        public LineStyles AxisYChartGridLineStyle
        {
            get
            {
                return axisYChartGridLineStyle;
            }

            set
            {
                axisYChartGridLineStyle = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴网格线宽度")]
        [Description("AxisYChartGridLineThickness")]
        [Editor(typeof(UI.XProperty.Editors.XIntEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYChartGridLineThickness", "网格线宽度")]
        public int AxisYChartGridLineThickness
        {
            get
            {
                return axisYChartGridLineThickness;
            }

            set
            {
                axisYChartGridLineThickness = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴网格线间隔颜色")]
        [Description("AxisYChartGridInterlacedColor")]
        [Editor(typeof(UI.XProperty.Editors.XBrushEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYChartGridInterlacedColor", "网格线间隔颜色")]
        public BrushEx AxisYChartGridInterlacedColor
        {
            get
            {
                return axisYChartGridInterlacedColor;
            }

            set
            {
                axisYChartGridInterlacedColor = value;
                Refresh();
            }
        }

        //[Category("Y轴")]
        //[DisplayName("Y轴网格线步长")]
        //[Description("AxisYChartGridInterval")]
        //[Editor(typeof(UI.XProperty.Editors.XDoubleNullEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        //[XProperty(XPropertyCategory.Other, "AxisYChartGridInterval", "网格线步长")]
        public double? AxisYChartGridInterval
        {
            get
            {
                return axisYChartGridInterval;
            }

            set
            {
                axisYChartGridInterval = value;
                Refresh();
            }
        }
        #endregion

        #region Tick
        [Category("Y轴")]
        [DisplayName("Y轴是否显示刻度")]
        [Description("AxisYTickEnabled")]
        [Editor(typeof(UI.XProperty.Editors.XBooleanEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTickEnabled", "是否显示刻度")]
        public bool AxisYTickEnabled
        {
            get
            {
                return axisYTickEnabled;
            }

            set
            {
                axisYTickEnabled = value;
                Refresh();
            }
        }

        //[Category("Y轴")]
        //[DisplayName("Y轴刻度步长")]
        //[Description("AxisYTickInterval")]
        //[Editor(typeof(UI.XProperty.Editors.XDoubleNullEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        //[XProperty(XPropertyCategory.Other, "AxisYTickInterval", "刻度步长")]
        public double? AxisYTickInterval
        {
            get
            {
                return axisYTickInterval;
            }

            set
            {
                axisYTickInterval = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴刻度线颜色")]
        [Description("AxisYTickLineColor")]
        [Editor(typeof(UI.XProperty.Editors.XBrushEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTickLineColor", "刻度线颜色")]
        public BrushEx AxisYTickLineColor
        {
            get
            {
                return axisYTickLineColor;
            }

            set
            {
                axisYTickLineColor = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴刻度线样式")]
        [Description("AxisYTickLineStyles")]
        [Editor(typeof(UI.DataPartLib.XProperty.Editors.XLineStylesEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTickLineStyles", "刻度线样式")]
        public LineStyles AxisYTickLineStyles
        {
            get
            {
                return axisYTickLineStyles;
            }

            set
            {
                axisYTickLineStyles = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴刻度线宽度")]
        [Description("AxisYTickLineThickness")]
        [Editor(typeof(UI.XProperty.Editors.XDoubleEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTickLineThickness", "刻度线宽度")]
        public double AxisYTickLineThickness
        {
            get
            {
                return axisYTickLineThickness;
            }

            set
            {
                axisYTickLineThickness = value;
                Refresh();
            }
        }

        [Category("Y轴")]
        [DisplayName("Y轴刻度线长度")]
        [Description("AxisYTickLength")]
        [Editor(typeof(UI.XProperty.Editors.XDoubleNullEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "AxisYTickLength", "刻度线长度")]
        public double? AxisYTickLength
        {
            get
            {
                return axisYTickLength;
            }

            set
            {
                axisYTickLength = value;
                Refresh();
            }
        }
        #endregion

        private bool isAutoReviseYAxis;
        [Category("Y轴")]
        [DisplayName("Y轴自动修正Y轴的刻度")]
        [Description("IsAutoReviseYAxis")]
        [Editor(typeof(UI.XProperty.Editors.XBooleanEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        [XProperty(XPropertyCategory.Other, "IsAutoReviseYAxis", "自动修正Y轴的刻度")]
        public bool IsAutoReviseYAxis
        {
            get
            {
                return isAutoReviseYAxis;
            }
            set
            {
                isAutoReviseYAxis = value;
                Refresh();
            }
        }

        //[Category("Y轴")]
        //[DisplayName("Y轴是否使用对数显示")]
        //[Description("AxisYLogarithmic")]
        //[Editor(typeof(UI.XProperty.Editors.XBooleanEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        //[XProperty(XPropertyCategory.Other, "AxisYLogarithmic", "Y轴是否使用对数显示")]
        public bool AxisYLogarithmic
        {
            get
            {
                return axisYLogarithmic;
            }

            set
            {
                axisYLogarithmic = value;
                Refresh();
            }
        }

        //[Category("Y轴")]
        //[DisplayName("Y轴使用对数底")]
        //[Description("AxisYLogarithmBase")]
        //[Editor(typeof(UI.XProperty.Editors.XIntEditor), typeof(UI.XProperty.XPropertyValueEditor))]
        //[XProperty(XPropertyCategory.Other, "AxisYLogarithmBase", "Y轴使用对数底")]
        public int AxisYLogarithmBase
        {
            get
            {
                return axisYLogarithmBase;
            }

            set
            {
                axisYLogarithmBase = value;
                Refresh();
            }
        }

        private bool axisYLogarithmic;

        private int axisYLogarithmBase;
    }
}
